/* $NoKeywords:$ */
/**
 * @file
 *
 * AMD Family_14 Microcode patch.
 *
 * Fam14 Microcode Patch rev 05000119 for 5020 or equivalent.
 *
 *
 */
/*
 ******************************************************************************
 *
 * Copyright (c) 2013, Advanced Micro Devices, Inc.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *     * Redistributions of source code must retain the above copyright
 *       notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright
 *       notice, this list of conditions and the following disclaimer in the
 *       documentation and/or other materials provided with the distribution.
 *     * Neither the name of Advanced Micro Devices, Inc. nor the names of
 *       its contributors may be used to endorse or promote products derived
 *       from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED. IN NO EVENT SHALL ADVANCED MICRO DEVICES, INC. BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 ******************************************************************************
 */
/*----------------------------------------------------------------------------------------
 *                             M O D U L E S    U S E D
 *----------------------------------------------------------------------------------------
 */
#include "AGESA.h"
#include "cpuRegisters.h"
#include "cpuEarlyInit.h"

/*----------------------------------------------------------------------------------------
 *                   D E F I N I T I O N S    A N D    M A C R O S
 *----------------------------------------------------------------------------------------
 */

/*----------------------------------------------------------------------------------------
 *                  T Y P E D E F S     A N D     S T R U C T U R E S
 *----------------------------------------------------------------------------------------
 */

// Encrypt Patch code 05000119 for 5020 and equivalent

CONST MICROCODE_PATCHES ROMDATA CpuF14MicrocodePatch05000119 =
{{
  0x13, 0x20, 0x18, 0x01, 0x19, 0x01, 0x00, 0x05,
  0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x20, 0x50, 0x00, 0x00, 0x00, 0xAA, 0xAA, 0xAA,
  0x55, 0xCB, 0x7C, 0x80, 0xF6, 0x0B, 0xB5, 0xB9,
  0xDB, 0x48, 0xC0, 0xC7, 0xC3, 0x4B, 0x3F, 0x8E,
  0x0C, 0xFE, 0xBB, 0x19, 0x27, 0xB0, 0x67, 0xE7,
  0x4D, 0xB6, 0xDF, 0x55, 0x39, 0x92, 0x14, 0x55,
  0x94, 0x94, 0x8F, 0xE1, 0x58, 0xE6, 0xE3, 0x99,
  0x34, 0x2B, 0x74, 0x74, 0xFF, 0x5E, 0x0E, 0xBF,
  0x20, 0xE5, 0xA5, 0x5E, 0xB2, 0xE7, 0xD0, 0xC9,
  0x78, 0x85, 0xB2, 0xE4, 0xFB, 0x48, 0x4A, 0xD9,
  0xE2, 0x9B, 0x58, 0x9B, 0x98, 0x5D, 0x2B, 0xC2,
  0xF1, 0xFC, 0x43, 0x76, 0x49, 0xCB, 0x9E, 0x1E,
  0x48, 0x0B, 0xF8, 0xE6, 0x51, 0xC6, 0x25, 0xBF,
  0x4F, 0x2D, 0x50, 0xDF, 0xC4, 0x29, 0x80, 0x44,
  0xAA, 0x2C, 0xF1, 0x4E, 0xE0, 0x0A, 0x25, 0xF0,
  0x43, 0x0A, 0x22, 0xD9, 0x89, 0xA2, 0x4B, 0x0A,
  0x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